package com.cn.springcloudshop.mapper;

import com.cn.springcloudshop.model.CountOrderStatusPOJO;
import com.cn.springcloudshop.model.YmShopOrder;
import com.cn.springcloudshop.model.YmShopOrderExample;
import org.apache.ibatis.annotations.Options;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface YmShopOrderMapper {
    int countByExample(YmShopOrderExample example);

    int deleteByExample(YmShopOrderExample example);

    int deleteByPrimaryKey(Long shopOrderId);

    int insert(YmShopOrder record);

    int insertSelective(YmShopOrder record);

    List<YmShopOrder> selectByExample(YmShopOrderExample example);

    YmShopOrder selectByPrimaryKey(Long shopOrderId);

    int updateByExampleSelective(@Param("record") YmShopOrder record, @Param("example") YmShopOrderExample example);

    int updateByExample(@Param("record") YmShopOrder record, @Param("example") YmShopOrderExample example);

    int updateByPrimaryKeySelective(YmShopOrder record);

    int updateByPrimaryKey(YmShopOrder record);

    int updateBatchByPK(@Param("orders") List<YmShopOrder> orders);

    List<CountOrderStatusPOJO> countByStatus(Long userId);
}